function ChessSteps() {
	var stepsX = new Array();
	var stepsY = new Array();
	
	this.x = 0;
	this.y = 0;
	
	this.addStep = function(x, y) {
		this.x = x;
		this.y = y;
		stepsX.push(this.x);
		stepsY.push(this.y);
	};
	
	this.backStep = function() {
		this.x = stepsX.pop();
		this.y = stepsY.pop();
		
		if ((this.x == undefined) || (this.y == undefined)) {
			this.x = 0;
			this.y = 0;
			return false;
		}
		
		return true;
	};
}